package com.dfrz.stockMarket.util;

import java.util.Comparator;
import java.util.Date;

import com.dfrz.stockMarket.model.StockLogModel;

public class SortDate implements Comparator<StockLogModel>{

	@Override
	public int compare(StockLogModel arg0, StockLogModel arg1) {
		Date d1 = arg0.getCreateDate();
		Date d2 = arg1.getCreateDate();
		if (d1.after(d2)) {
			return 1;
		}
		return -1;
	}

}